package com.lisa.util;

import javax.servlet.ServletConfig;
import javax.servlet.http.HttpServlet;

public class UtilCommon {

	/** 数据库驱动 */
	public static String DRIVER = "oracle.jdbc.driver.OracleDriver";
	/** 数据库类型 IP, */
//	public static String URL 	= "jdbc:oracle:" + "thin:@122.224.94.108:8004:gadata";
	public static String URL	= "jdbc:oracle:" + "thin:@172.17.1.42:1521:gadata";
	
	/** 账户名 */
	public static String USERNAME = "sgxtv2"/*"DCH"*/;
	/** 账户密码 */
	public static String PASSWORD = "thsw_1234"/*"123456"*/;
	
	
	
	/**初始化service的配置文件参数
	 * @param servlet
	 */
	public static void initConfigParam(HttpServlet servlet){
		ServletConfig config = servlet.getServletConfig();
		DRIVER = config.getInitParameter("DRIVER");
		URL = config.getInitParameter("URL");
		USERNAME = config.getInitParameter("USERNAME");
		PASSWORD = config.getInitParameter("PASSWORD");
	}
}
